package Textbookmanagement;

import java.util.Scanner;

public class zhulei {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        Order order = new Order();
        Sell sell = new Sell();
        Statistics statistics = new Statistics();
        Inventory inventory = new Inventory();
        while (true) {
            System.out.println("***------教材管理系统------***");
            System.out.println("1.教材订购           2.教材出售");
            System.out.println("3.教材统计           4.库存管理");
            System.out.println("                    0.退出");
            System.out.println("***----------------------***");
            int input = sc.nextInt();
            if (input == 1) {
                order.show();
                int i = sc.nextInt();
                switch (i) {
                    case 1:
                        order.InformationRegistration();
                        break;
                    case 2:
                        order.InformationInquiry();
                        break;
                    case 0:
                        System.out.println("正在返回上级菜单...");
                        break;
                }
            } else if (input == 2) {
                sell.show();
                int i = sc.nextInt();
                switch (i) {
                    case 1:
                        sell.Saleentry();
                        break;
                    case 2:
                        sell.SalesInquiries();
                        break;
                    case 0:
                        System.out.println("正在返回上级菜单...");
                        break;
                }
            } else if (input == 3) {
                statistics.show();
                int i = sc.nextInt();
                switch (i) {
                    case 1:
                        statistics.Dailystatistics();
                        break;
                    case 2:
                        statistics.librarylocation();
                        break;
                    case 3:
                        statistics.SaleSstatistics();
                        break;
                    case 0:
                        System.out.println("正在返回上级菜单...");
                        break;
                }

            } else if (input == 4) {
                inventory.show();
                int i = sc.nextInt();
                switch (i) {
                    case 1:
                        inventory.Inventoryinformation();
                        break;
                    case 2:
                        inventory.Inventoryalerts();
                        break;
                    case 0:
                        break;
                }
            } else if (input == 0) {
                System.out.println("正在退出...");
                break;
            }
        }
    }
}

